<script setup lang="ts">
import { onMounted, ref, watch } from "vue";
import { formRules } from "../utils/rule";
import { resetProps } from "../utils/types";

const props = withDefaults(defineProps<resetProps>(), {
  formInline: () => ({
    id: 0,
    userPass: ""
  })
});
import { useRole } from "../utils/hook";
const treeRef = ref();
const tableRef = ref();
const { allCustomer } = useRole(tableRef, treeRef);
const ruleFormRef = ref();
const newFormInline = ref(props.formInline);
console.log("xiugai ", props.formInline);
function getRef() {
  return ruleFormRef.value;
}
const userStateBoolean = ref(true);

defineExpose({ getRef });
</script>

<template>
  <el-form
    ref="ruleFormRef"
    :model="newFormInline"
    :rules="formRules"
    label-width="102px"
  >
    <el-form-item label="用户密码" prop="userPass">
      <el-input
        v-model="newFormInline.userPass"
        clearable
        placeholder="请输入用户密码"
        type="password"
      />
    </el-form-item>
  </el-form>
</template>
